package com.erp.account.dao.idl;

import java.util.BitSet;
import java.util.Date;
import java.util.Map;
import java.util.Set;

import com.paipai.lang.uint64_t;
import com.paipai.lang.uint16_t;
import com.paipai.lang.uint32_t;
import com.paipai.lang.uint8_t;
import com.paipai.util.annotation.Field;
import com.paipai.util.annotation.HeadApiProtocol;
import com.paipai.util.annotation.Member;

/**
 * 云ERP账户dao的ddo
 * 
 * @author blucelu
 * @version 1.0, 2013-10-14
 * 
 */

public class AccountDdo
{
	/**
	 * 
	 * 分支机构DDO
	 * 
	 * @author blucelu
	 * 
	 */
	@Member(cPlusNamespace = "erp::account::ddo", desc = "来往单位DDO", isNeedUFlag = true)
	public class BusinessUnitsDdo
	{
		@Field(desc = "版本号  ", defaultValue = "0", optional = true)
		uint32_t version;
		
		@Field(desc = "往来单位SysNo", optional = true)
		uint64_t businessUnitsSysNo;
		
		@Field(desc = "往来单位类型", optional = true)
		uint16_t businessUnitsType;
		
		@Field(desc = "编号", optional = true)
		String businessUnitsID;
		
		@Field(desc = "全称", optional = true)
		String fullName;
		
		@Field(desc = "简称", optional = true)
		String name;
		
		@Field(desc = "拼音码", optional = true)
		String pyCode;
		
		@Field(desc = "建档日期", optional = true)
		uint32_t createDate;
		
		@Field(desc = "付款期限", optional = true)
		uint32_t payDueTime;
		
		@Field(desc = "扣率", optional = true)
		uint32_t discountRate;
		
		@Field(desc = "适用预售/购价格Level", optional = true)
		uint16_t prePriceLevel;
		
		@Field(desc = "电话", optional = true)
		String telephone;
		
		@Field(desc = "传真", optional = true)
		String fax;
		
		@Field(desc = "电子邮件", optional = true)
		String email;
		
		@Field(desc = "网络地址", optional = true)
		String netAddress;
		
		@Field(desc = "邮编", optional = true)
		String zipCode;
		
		@Field(desc = "地址", optional = true)
		String address;
		
		@Field(desc = "银行账号", optional = true)
		String bankAccount;
		
		@Field(desc = "银行户名", optional = true)
		String bankAccountName;
		
		@Field(desc = "父往来单位SysNo", optional = true)
		uint64_t parentSysNo;
		
		@Field(desc = "结算单位SysNo", optional = true)
		uint64_t clearingContactUnitSysNo;
		
		@Field(desc = "地区SysNo", optional = true)
		uint64_t areaSysNo;
		
		@Field(desc = "职员SysNo", optional = true)
		uint64_t staffSysNo;
		
		@Field(desc = "开户银行", optional = true)
		String bankName;
		
		@Field(desc = "备注", optional = true)
		String comment;
		
		@Field(desc = "联系人SysNos", optional = true)
		String contactSysNos;
		
		@Field(desc = "往来单位属性,只读", bitset = 32, optional = true)
		BitSet businessUnitsProperty;
		
		@Field(desc = "往来单位属性,设置", bitset = 32, optional = true)
		BitSet businessUnitsPropertyInclude;
		
		@Field(desc = "往来单位属性,取消", bitset = 32, optional = true)
		BitSet businessUnitsPropertyExclude;
		
		@Field(desc = "往来单位状态", optional = true)
		uint32_t businessUnitsStatus;
		
		@Field(desc = "创建人SysNo", optional = true)
		uint64_t creatorSysNo;
		
		@Field(desc = "创建时间", optional = true)
		uint32_t rowCreatDate;
		
		@Field(desc = "编辑者SysNo", optional = true)
		uint64_t modifierSysNo;
		
		@Field(desc = "编辑时间", optional = true)
		uint32_t rowModifyDate;
	}

	/**
	 * 
	 * 组织机构Filter
	 * 
	 * @author blucelu
	 * 
	 */
	@Member(cPlusNamespace = "erp::account::ddo", desc = "来往单位Filter", isNeedUFlag = true)
	public class BusinessUnitsFilterDdo
	{
		@Field(desc = "版本号", defaultValue = "0", optional = true)
		uint32_t version;

		@Field(desc = "页码，从0开始，必填", optional = true)
		uint32_t page;

		@Field(desc = "页面大小，服务通过配置进行最大值限制，必填", optional = true)
		uint32_t pageSize;

		@Field(desc = "排序方式，参见相关枚举定义，必填", optional = true)
		uint32_t orderType;
		
		@Field(desc = "父来往单位SysNos", optional = true)
		Set<uint64_t> parentSysNo;

		@Field(desc = "来往单位全称", optional = true)
		String fullName;

		@Field(desc = "来往单位简称", optional = true)
		String name;

		@Field(desc = "来往单位编码", optional = true)
		String code;

		@Field(desc = "来往单位拼音码", optional = true)
		String pinyinCode;

		@Field(desc = "状态", optional = true)
		Set<uint32_t> status;

		@Field(desc = "包含属性，且或关系由PropertyOption指定", bitset = 32, optional = true)
		BitSet propertyInclude;

		@Field(desc = "包含属性选项：0：且的关系；1，或的关系", optional = true)
		uint16_t propertyOption;

		@Field(desc = "排除属性，与PropertyInclude为且关系 ", bitset = 32, optional = true)
		BitSet propertyExclude;

		@Field(desc = "扩展", optional = true)
		Map<String, String> extern;
	}
	
	
	/**
	 * 
	 * 职员PO
	 * 
	 * @author blucelu
	 * 
	 */
	@Member(cPlusNamespace = "erp::account::ddo", desc = "职员DDO", isNeedUFlag = true)
	public class EmployeeDdo
	{
		@Field(desc = "版本号  ", defaultValue = "0", optional = true)
		uint32_t version;
		
		@Field(desc = "职员SysNo", optional = true)
		uint64_t staffSysNo;
		
		@Field(desc = "职员姓名", optional = true)
		String name;
		
		@Field(desc = "分支机构SysNo", optional = true)
		uint64_t branchSysNo;
		
		@Field(desc = "部门SysNo", optional = true)
		uint64_t departmentSysNo;
		
		@Field(desc = "拼音码", optional = true)
		String pyCode;
		
		@Field(desc = "每单抹零限额", optional = true)
		uint64_t perLimit;
		
		@Field(desc = "提成比例", optional = true)
		uint32_t commissionPercent;
		
		@Field(desc = "备注", optional = true)
		String comment;
		
		@Field(desc = "移动电话", optional = true)
		String phone;
		
		@Field(desc = "办公电话", optional = true)
		String tel;
		
		@Field(desc = "住宅电话", optional = true)
		String homeTel;
		
		@Field(desc = "电子邮件", optional = true)
		String email;
		
		@Field(desc = "紧急联系人", optional = true)
		String contact;
		
		@Field(desc = "邮编", optional = true)
		String zipCode;
		
		@Field(desc = "联系地址", optional = true)
		String address;
		
		@Field(desc = "QQ", optional = true)
		String qQ;
		
		@Field(desc = "微博账号", optional = true)
		String weiBoAccount;
		
		@Field(desc = "个人博客", optional = true)
		String blog;
		
		@Field(desc = "性别", optional = true)
		uint16_t sex;
		
		@Field(desc = "民族", optional = true)
		String nation;
		
		@Field(desc = "出生日期", optional = true)
		uint32_t birthday;
		
		@Field(desc = "到岗时间", optional = true)
		uint32_t joinedDate;
		
		@Field(desc = "身高", optional = true)
		uint16_t height;
		
		@Field(desc = "体重", optional = true)
		uint16_t weight;
		
		@Field(desc = "血型", optional = true)
		String bloodType;
		
		@Field(desc = "健康状况", optional = true)
		String tealth;
		
		@Field(desc = "职位", optional = true)
		String position;
		
		@Field(desc = "职称", optional = true)
		String technicalTitle;
		
		@Field(desc = "毕业院校", optional = true)
		String graduatedInstitution;
		
		@Field(desc = "学历", optional = true)
		String education;
		
		@Field(desc = "专业", optional = true)
		String profession;
		
		@Field(desc = "电脑能力", optional = true)
		String computerLevel;
		
		@Field(desc = "外语语种", optional = true)
		String foreignLanguageKind;
		
		@Field(desc = "外语水平", optional = true)
		String foreignLevel;
		
		@Field(desc = "籍贯", optional = true)
		String nativeName;
		
		@Field(desc = "政治面貌", optional = true)
		String politicalStatus;
		
		@Field(desc = "婚姻状况", optional = true)
		uint16_t married;
		
		@Field(desc = "家庭情况", optional = true)
		String family;
		
		@Field(desc = "身份证", optional = true)
		String iDCard;
		
		@Field(desc = "户口地址", optional = true)
		String hukouAddress;
		
		@Field(desc = "地区SysNo", optional = true)
		uint64_t areaSysNo;
		
		@Field(desc = "职员属性,只读", bitset = 32, optional = true)
		BitSet property;
		
		@Field(desc = "职员属性,设置", bitset = 32, optional = true)
		BitSet propertyInclude;
		
		@Field(desc = "职员属性,取消", bitset = 32, optional = true)
		BitSet propertyExclude;
		
		@Field(desc = "职员状态", optional = true)
		uint32_t status;
		
		@Field(desc = "创建人SysNo", optional = true)
		uint64_t creatorSysNo;
		
		@Field(desc = "创建时间", optional = true)
		uint32_t rowCreatDate;
		
		@Field(desc = "编辑者SysNo", optional = true)
		uint64_t modifierSysNo;
		
		@Field(desc = "编辑时间", optional = true)
		uint32_t rowModifyDate;

	}
	
	/**
	 * 
	 * 职员
	 * Filter
	 * 
	 * @author blucelu
	 * 
	 */
	@Member(cPlusNamespace = "erp::account::ddo", desc = "职员Filter", isNeedUFlag = true)
	public class EmployeeFilterDdo
	{
		@Field(desc = "版本号", defaultValue = "0", optional = true)
		uint32_t version;

		@Field(desc = "页码，从0开始，必填", optional = true)
		uint32_t page;

		@Field(desc = "页面大小，服务通过配置进行最大值限制，必填", optional = true)
		uint32_t pageSize;

		@Field(desc = "排序方式，参见相关枚举定义，必填", optional = true)
		uint32_t orderType;
		
		@Field(desc = "分支机构SysNo", optional = true)
		uint64_t branchSysNo;
		
		@Field(desc = "部门SysNo", optional = true)
		uint64_t departmentSysNo;

		@Field(desc = "姓名", optional = true)
		String name;
		
		@Field(desc = "拼音码", optional = true)
		String pinyinCode;

		@Field(desc = "状态", optional = true)
		Set<uint32_t> status;

		@Field(desc = "包含属性，且或关系由PropertyOption指定", bitset = 32, optional = true)
		BitSet propertyInclude;

		@Field(desc = "包含属性选项：0：且的关系；1，或的关系", optional = true)
		uint16_t propertyOption;

		@Field(desc = "排除属性，与PropertyInclude为且关系 ", bitset = 32, optional = true)
		BitSet propertyExclude;

		@Field(desc = "扩展", optional = true)
		Map<String, String> extern;
	}
	
	/**
	 * 
	 * 信用额度
	 * Po
	 * 
	 * @author blucelu
	 * 
	 */
	@Member(cPlusNamespace = "erp::account::ddo", desc = "信用额度DDO", isNeedUFlag = true)
	public class CustomerCreditDdo
	{
		@Field(desc = "版本号", defaultValue = "0", optional = true)
		uint32_t version;

		@Field(desc = "分支机构SysNo", optional = true)
		uint64_t branchSysNo;
		
		@Field(desc = "往来单位SysNo", optional = true)
		uint64_t businessUnitsSysNo;
		
		@Field(desc = "信用额度", optional = true)
		uint64_t creditLine;
		
		@Field(desc = "创建人SysNo", optional = true)
		uint64_t creatorSysNo;
		
		@Field(desc = "创建时间", optional = true)
		uint32_t rowCreatDate;
		
		@Field(desc = "编辑者SysNo", optional = true)
		uint64_t modifierSysNo;
		
		@Field(desc = "编辑时间", optional = true)
		uint32_t rowModifyDate;
	}
	
	/**
	 * 
	 * 联系人
	 * Filter
	 * 
	 * @author blucelu
	 * 
	 */
	@Member(cPlusNamespace = "erp::account::ddo", desc = "联系人DDO", isNeedUFlag = true)
	public class ContactDdo
	{
		@Field(desc = "版本号", defaultValue = "0", optional = true)
		uint32_t version;

		@Field(desc = "联系人SysNo", optional = true)
		uint64_t contactSysNo;
		
		@Field(desc = "地区SysNo", optional = true)
		uint64_t areaSysNo;
		
		@Field(desc = "姓名", optional = true)
		String name;
		
		@Field(desc = "性别", optional = true)
		uint16_t sex;
		
		@Field(desc = "生日", optional = true)
		uint32_t birthday;
		
		@Field(desc = "职位", optional = true)
		String position;
		
		@Field(desc = "称呼", optional = true)
		String alias;
		
		@Field(desc = "邮件", optional = true)
		String mail;
		
		@Field(desc = "电话", optional = true)
		String tel;
		
		@Field(desc = "手机", optional = true)
		String phone;
		
		@Field(desc = "邮编", optional = true)
		String zipCode;
		
		@Field(desc = "地址", optional = true)
		String address;
		
		@Field(desc = "备注", optional = true)
		String comment;
		
		@Field(desc = "联系人属性,只读", bitset = 32, optional = true)
		BitSet property;
		
		@Field(desc = "联系人属性,设置", bitset = 32, optional = true)
		BitSet propertyInclude;
		
		@Field(desc = "联系人属性,取消", bitset = 32, optional = true)
		BitSet propertyExclude;
		
		@Field(desc = "联系人状态", optional = true)
		uint32_t status;
		
		@Field(desc = "创建人SysNo", optional = true)
		uint64_t creatorSysNo;
		
		@Field(desc = "创建时间", optional = true)
		uint32_t rowCreatDate;
		
		@Field(desc = "编辑者SysNo", optional = true)
		uint64_t modifierSysNo;
		
		@Field(desc = "编辑时间", optional = true)
		uint32_t rowModifyDate;
	}
	
	/**
	 * 
	 * 联系人
	 * Filter
	 * 
	 * @author blucelu
	 * 
	 */
	@Member(cPlusNamespace = "erp::account::ddo", desc = "联系人Filter", isNeedUFlag = true)
	public class ContactFilterDdo
	{
		@Field(desc = "版本号", defaultValue = "0", optional = true)
		uint32_t version;

		@Field(desc = "页码，从0开始，必填", optional = true)
		uint32_t page;

		@Field(desc = "页面大小，服务通过配置进行最大值限制，必填", optional = true)
		uint32_t pageSize;

		@Field(desc = "排序方式，参见相关枚举定义，必填", optional = true)
		uint32_t orderType;

		@Field(desc = "姓名", optional = true)
		String name;

		@Field(desc = "地区SysNo", optional = true)
		uint64_t areaSysNo;

		@Field(desc = "状态", optional = true)
		Set<uint32_t> status;

		@Field(desc = "包含属性，且或关系由PropertyOption指定", bitset = 32, optional = true)
		BitSet propertyInclude;

		@Field(desc = "包含属性选项：0：且的关系；1，或的关系", optional = true)
		uint16_t propertyOption;

		@Field(desc = "排除属性，与PropertyInclude为且关系 ", bitset = 32, optional = true)
		BitSet propertyExclude;

		@Field(desc = "扩展", optional = true)
		Map<String, String> extern;
	}
}

}
